package br.usp.icmc.biomac.client.view.lixo;

import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Tree;
import com.google.gwt.user.client.ui.TreeItem;

public class LexiconsTreeTab extends Composite {

	private Tree tree;

	public LexiconsTreeTab() {
		tree = new Tree();
		for (int i =0; i<10; i++){
			TreeItem root = new TreeItem("ImageAnnotation");
			tree.addItem(root);
			addImageItem(root, "user");
			addImageItem(root, "anatomicEntityCollection");
			addImageItem(root, "imagingObservationCollection");
			addImageItem(root, "geometricShapeCollection");
			addImageItem(root, "patient");
			addImageItem(root, "imageReferenceCollection");
			root.setState(true);	
		}
	    initWidget(tree);
	}

	private TreeItem addImageItem(TreeItem root, String title) {
		TreeItem item = new TreeItem(title);
		root.addItem(item);
		return item;
	}
}
